<%! 
import templates.filters
from string import capitalize
%>
<!doctype html> 
<html lang="en">
	<head>
		<title>Have or Want<%block name="title"></%block></title>
		
		<meta charset="utf-8">
		<meta name="description" content="simple classified ads">
		<meta name="author" content="arkanciscan@gmail.com">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0">
		<meta name="apple-mobile-web-app-capable" content="yes">
		<meta name="apple-mobile-web-app-status-bar-style" content="black">
		
		<link rel="shortcut icon" href="/static/favicon.ico">
		<link rel="apple-touch-icon" href="/static/apple-touch-icon.png">
		<link rel="stylesheet" href="/static/main.css">
		<link rel="stylesheet" media="screen and (min-width: 640px)" href="/static/wide.css">
	</head>
	<body>
		<header>
			%if user_nickname:
				<a href="/settings">${user_nickname}</a>
			%else:
				<a href="${user_link}">
					<img src="/static/google-icon.png" alt="Google icon" width="16">
					${user_action}
				</a>
			%endif
			<h1>
				<a
					%if type=='have':
						class="selected"
					%endif
				href="/have">Have</a> 
				<span>or</span> 
				<a
				%if type=='want':
					class="selected"
				%endif
				href="/want">Want</a>
			</h1>
		</header>
		
		<nav>
			<%block name="nav">
				%if type=='have' or type=='want':
					<a
					%if things and not other_user_id and not is_owner:
						class="selected"
					%endif
					href="/${type}">All ${type|capitalize}</a>
					<a
						%if (user_id and user_id==other_user_id) and is_owner:
							class="selected"
						%endif
						href="/${type}/you">You ${type|capitalize}</a>
					<a
						%if thing and is_owner and not thing.answers:
							class="selected"
						%endif
					href="/${type}?method_post=please">New ${type|capitalize}</a>
				%else:
					<a>&nbsp;</a>
				%endif
			</%block>
		</nav>
		
		<div id="content">
			<%block name="content">
				<section>
					<h2>Here's how it works</h2>
					<ol>
						<li>Tell us something you <a href="/want/you">want</a> to get
						<li>Answer questions about it
						<li>Tell us something you <a href="/have/you">have</a> to get rid of
						<li>Answer questions about it
					</ol>
					
					<h3>And then!</h3>
					<ul>
						<li>We show you people that have what you want
						<li>We tell people about what you have
						<li>Then you trade (some day)
						<li>:-)
					</ul>
					
				 </section>
				 
				 <aside>
					<h3>Other Features</h3>
					<p>Email photos from your smart phone to <a href="mailto:have@haveorwant.appspotmail.com">have@haveorwant...</a> or <a href="mailto:want@haveorwant.appspotmail.com">want@haveorwant...</a> to instantly create new posts. Just answer the question "What is it?" in the subject to get started.</p>
					
					<h3>Coming Soon</h3>
					<ul>
						<li>Make/accept offers in money or trade
						<li>Post things you have or want on Facebook or Twitter
						<li>Find things located near you
					</ul>
				 </aside>
				 
			</%block>
		</div>
		
		<footer>
			<a href="/">About</a>
			<a href="/privacy">Privacy Policy</a>
			<a href="/terms">Terms of Use</a>
			&copy;2011 <a href="mailto:arkancsican@gmail.com">Jesse Hattabaugh</a>
			<a href="/credits">Credits</a>
			<img src="http://code.google.com/appengine/images/appengine-silver-120x30.gif" 
alt="Powered by Google App Engine" />
		</footer>
			
		<script src="//ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.js"></script>
		<script>!window.jQuery && document.write(unescape('%3Cscript src="/static/jquery-1.4.2.min.js"%3E%3C/script%3E'))</script>
		<script src="/static/modernizr-1.6.min.js"></script>
		<script><%block name="script"></%block></script>
		
		<!--[if lt IE 8]>
		<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/chrome-frame/1/CFInstall.min.js"></script>
		<script>
			window.attachEvent("onload", function() {
				CFInstall.check({
					mode:'overlay'
				});
			});
		</script>
		<![endif]-->
		
		%if debug:
			<pre>${debug}</pre>
		%endif
	
	</body>
</html>	